<?php 
require 'Home/View/template/header.php';
$uname = $_SESSION['user'];
?>
<br/>
<div class="alert alert-success" role="alert">
	<h3 class="text-center">个人中心</h3>
	<h5 class="text-center"><?php echo $uname; ?></h5>
</div>
<br/>
<div class="jumbotron">
	<div class="media">
		<a  class="media-left" >
			<img src="asset/images/<?php echo $data['pic']; ?>" width=150px height=150px alt="暂无头像" class="img-rounded">
		</a>
		<div class="media-right media-body">
			<div class="col-md-1"></div>
			<div class="col-md-5">
				<table class="table table-striped table-hover text-center">
					<tr>
						<td width=25%>用户名</td>
						<td width=75%><?php echo $uname; ?></td>
					</tr>
					<tr>
						<td width=25%>性 别</td>
						<td width=75%><?php if($data['gender'] == "0") {echo "男";}else{echo "女";} ?></td>
					</tr>
					<tr>
						<td width=25%>年 龄</td>
						<td width=75%><?php echo $data['age']; ?></td>
					</tr>
					<tr>
						<td width=25%>我 是</td>
						<td width=75%><?php if($data['flag'] == "0") {echo "买家";} else {echo "卖家";} ?></td>
					</tr>
					<tr>
						<td width=25%>联系电话</td>
						<td width=75%><?php echo $data['tel']; ?></td>
					</tr>
				</table>
			</div>
			<div class="col-md-2 text-center">
				<h5>修改成==></h5>
			</div>
			<div class="col-md-4 text-center">
				<form action="index.php?c=user&m=userupdate&uid=<?php echo $data['uid']; ?>" enctype="multipart/form-data" class="form-horizontal" method="post">
					<div class="form-group">
						<input type="text" name="uname" class="form-control" placeholder="username">
					</div>
					<div class="form-group">
					<input type="radio" name="flag" value=0 <?php if($data['flag']==0) echo "checked" ?>> 买家&nbsp;&nbsp;
					<input type="radio" name="flag" value=1 <?php if($data['flag']==1) echo "checked" ?>> 卖家
					</div>
					<div class="form-group">
						<input type="text" name="age" class="form-control" placeholder="age">
					</div>
					<div class="form-group">
						<input type="text" name="tel" class="form-control" placeholder="tel">
					</div>
					<div class="form-group">
						<input type="submit" class="btn btn-success" value="修改">
						<input type="reset" class="btn btn-primary" value="重置">
					</div>
				</form>
			</div>
		</div>
	</div>
</div>
<?php require 'Home/View/template/footer.php'; ?>